<?php

namespace App\Http\Criteria;

use App\Repository\Criteria;
use App\Repository\Constracts\RepositoryInterface as Repository;

class GoodsIDCriteria extends Criteria
{
    private $goodsId;

    public function __construct($goodsId)
    {
        $this->goodsId = $goodsId;
    }

    public function apply($model, Repository $repository)
    {
        return $model->where('goods_id', $this->goodsId);
    }

}
